Include a header file required for build on mac 10.4
[supercollider.git] / Help / Extending and Customizing SC / Quarks / Quark.html
blob37b7c2db97d19ac0d6a8f7e5a95142139fb39ffc
1 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
2 <html>
3 <head>
4 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
5 <meta http-equiv="Content-Style-Type" content="text/css">
6 <title></title>
7 <meta name="Generator" content="Cocoa HTML Writer">
8 <meta name="CocoaVersion" content="824.44">
9 <style type="text/css">
10 p.p1 {margin: 0.0px 0.0px 0.0px 0.0px; font: 19.0px Helvetica}
11 p.p2 {margin: 0.0px 0.0px 0.0px 0.0px; font: 9.0px Monaco; min-height: 12.0px}
12 p.p3 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Helvetica}
13 p.p4 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Helvetica; min-height: 14.0px}
14 p.p5 {margin: 0.0px 0.0px 0.0px 0.0px; font: 14.0px Helvetica; min-height: 17.0px}
15 p.p6 {margin: 0.0px 0.0px 0.0px 0.0px; font: 14.0px Helvetica}
16 p.p7 {margin: 0.0px 0.0px 0.0px 0.0px; font: 9.0px Monaco}
17 p.p8 {margin: 0.0px 0.0px 0.0px 0.0px; font: 9.0px Monaco; color: #a8220e}
18 p.p9 {margin: 0.0px 0.0px 0.0px 0.0px; font: 9.0px Monaco; color: #606060}
19 span.s1 {color: #0933e8}
20 span.s2 {color: #000000}
21 span.s3 {color: #316f11}
22 span.s4 {color: #606060}
23 span.Apple-tab-span {white-space:pre}
24 </style>
25 </head>
26 <body>
27 <p class="p1"><b>Quark</b></p>
28 <p class="p2"><br></p>
29 <p class="p3">see <a href="./Quarks.html"><span class="s1">Quarks</span></a> first</p>
30 <p class="p4"><br></p>
31 <p class="p3">A Quark is a package of SC classes, helpfiles, C++ source for UGens and other SC code.</p>
32 <p class="p4"><br></p>
33 <p class="p3">A Quark object is created from the quark file found in {Application Support}/quarks/DIRECTORY</p>
34 <p class="p4"><br></p>
35 <p class="p3">These Quark objects are mostly used just by the Quarks class, and you usually don't need to deal with them at all.</p>
36 <p class="p4"><br></p>
37 <p class="p3"><b>But to publish a quark,<span class="Apple-converted-space">  </span>you do need to make the quark file.</b></p>
38 <p class="p5"><br></p>
39 <p class="p6"><b>Format of the .quark File</b></p>
40 <p class="p5"><br></p>
41 <p class="p3">This quarkfile is written in sc code, and should contain a dictionary with basic information about the package.</p>
42 <p class="p5"><br></p>
43 <p class="p7">(</p>
44 <p class="p8">// required:</p>
45 <p class="p9"><span class="s2"><span class="Apple-tab-span"> </span></span><span class="s3">\name</span><span class="s2">: <span class="Apple-tab-span"> </span><span class="Apple-tab-span"> </span></span>"theName"<span class="s2">,</span></p>
46 <p class="p8"><span class="s2"><span class="Apple-tab-span"> </span></span><span class="s3">\path</span><span class="s2">: <span class="Apple-tab-span"> </span><span class="Apple-tab-span"> </span></span><span class="s4">"foldername"</span><span class="s2">, </span>// almost always the same as the quark name</p>
47 <p class="p9"><span class="s2"><span class="Apple-tab-span"> </span></span><span class="s3">\summary</span><span class="s2">:<span class="Apple-tab-span"> </span><span class="Apple-tab-span"> </span></span>"Human readable summary",</p>
48 <p class="p9"><span class="s2"><span class="Apple-tab-span"> </span></span><span class="s3">\author</span><span class="s2">: <span class="Apple-tab-span"> </span><span class="Apple-tab-span"> </span></span>"My Name"<span class="s2">,</span></p>
49 <p class="p2"><br></p>
50 <p class="p8">// optional:</p>
51 <p class="p8"><span class="s2"><span class="Apple-tab-span"> </span></span><span class="s3">\version</span><span class="s2">:<span class="Apple-tab-span"> </span><span class="Apple-tab-span"> </span>1.0, </span>// must be a float</p>
52 <p class="p9"><span class="s2"><span class="Apple-tab-span"> </span></span><span class="s3">\organization</span><span class="s2">: <span class="Apple-tab-span"> </span></span>"My Organization"<span class="s2">,</span></p>
53 <p class="p9"><span class="s2"><span class="Apple-tab-span"> </span></span><span class="s3">\country</span><span class="s2">: <span class="Apple-tab-span"> </span><span class="Apple-tab-span"> </span></span>"My Country"<span class="s2">,</span></p>
54 <p class="p7"><span class="Apple-tab-span"> </span><span class="s3">\since</span>: <span class="Apple-tab-span"> </span><span class="Apple-tab-span"> </span><span class="s4">"2004"</span>,</p>
55 <p class="p9"><span class="s2"><span class="Apple-tab-span"> </span></span><span class="s3">\helpdoc</span><span class="s2">: </span>"theName.html"<span class="s2">,</span></p>
56 <p class="p9"><span class="s2"><span class="Apple-tab-span"> </span></span><span class="s3">\ext_dependancy</span><span class="s2">: </span>"Information on additional software needed to run this quark properly"<span class="s2">,</span></p>
57 <p class="p9"><span class="s2"><span class="Apple-tab-span"> </span></span><span class="s3">\url</span><span class="s2">: <span class="Apple-converted-space">          </span></span>"http://www.strangeQuark.de"<span class="s2">,</span></p>
58 <p class="p2"><br></p>
59 <p class="p8">// If the quark depends on other quarks, you can specify it as a list containing:</p>
60 <p class="p8">// (1) strings (just the quark name)</p>
61 <p class="p9"><span class="s2"><span class="Apple-tab-span"> </span></span><span class="s3">\dependencies</span><span class="s2">: </span>"nameOfDependantQuark"</p>
62 <p class="p8">// (2) key-&gt;value pairs (name-&gt;version)</p>
63 <p class="p8">//<span class="Apple-tab-span"> </span>\dependencies: [("nameOfDependantQuark" -&gt; 1.0)]</p>
64 <p class="p8">// or (3) arrays with info in this order: [name, version, repositoryBaseUrl]</p>
65 <p class="p8">//<span class="Apple-tab-span"> </span>\dependencies: [["nameOfDependantQuark", 1.0, "https://svn.weirdserver.be/trunk/weirdquarks"]]</p>
66 <p class="p2"><br></p>
67 <p class="p7">)</p>
68 <p class="p2"><br></p>
69 <p class="p3">Of particular importance for the Quarks interface class is the PATH.<span class="Apple-converted-space">  </span>This is the path relative to the quark directory.<span class="Apple-converted-space">  </span>In most cases this is simply the name of the quark and also the name of the folder. <span class="Apple-converted-space"> </span></p>
70 <p class="p4"><br></p>
71 <p class="p3">However, you may wish to create a parent folder and then keep several quarks inside that, in which case your path would be : parentfolder/quarkname</p>
72 <p class="p4"><br></p>
73 <p class="p3">It may even be possible to nest quarks inside of quarks (a kind of aggregate package), though a better way to do that would be to define an empty quark (the aggregate) and specify the other sub quarks as dependencies.</p>
74 <p class="p2"><br></p>
75 <p class="p3"><b>Please test that you don't have any syntax errors in your quark file before commiting it.</b></p>
76 <p class="p3">Thank you.</p>
77 <p class="p4"><br></p>
78 <p class="p4"><br></p>
79 </body>
80 </html>